home *** CD-ROM | disk | FTP | other *** search
/ Night Owl 6 / Night Owl's Shareware - PDSI-006 - Night Owl Corp (1990).iso / 015a / abba1bat.zip / MOVE.BAT < prev    next >
DOS Batch File  |  1991-11-15  |  1KB  |  43 lines

  1. @echo off
  2. rem this file: MOVE.BAT
  3. rem
  4. rem (C) 1991 Abba Software Co.
  5. rem
  6. if not %1! == ! goto checktwo
  7. echo :::::::::::::::::::::::::::::::::::::::::::::::::::::
  8. echo :::                                               :::
  9. echo ::: Parameters must be supplied.                  :::
  10. echo :::                                               :::
  11. echo ::: Syntax:                                       :::
  12. echo :::    MOVE (\dir\file(set)) (\dir[\file(set)])   :::
  13. echo :::                                               :::
  14. echo ::: These parameters are the same as those for    :::
  15. echo ::: the Copy command.                             :::
  16. echo ::::::::::::::::::::::::::::::::::::::::::::::::::::: 
  17. goto end
  18. :checktwo
  19. rem 
  20. rem %2 is a filename
  21. rem %2%1 is the root dir and a filename
  22. rem %2\%1 is a directory and a filename
  23. if exist %2 goto itexists
  24. if exist %2%1 goto itexists
  25. if exist %2\%1 goto itexists
  26. goto copy
  27. :itexists
  28. if %2! == ! goto copy
  29. echo ::::::::::::::::::::::::::::::::::::::::::::::
  30. echo :::                                        :::
  31. echo ::: %1 is already in %2        :::
  32. echo :::                                        :::
  33. echo ::: to stop copy press the break key, or   ::: 
  34. echo ::: press the Ctl and C keys simultaneously:::
  35. echo ::::::::::::::::::::::::::::::::::::::::::::::
  36. pause
  37. goto copy
  38. :copy
  39. copy %1 %2
  40. if not errorlevel 0 goto end
  41. del %1
  42. :end 
  43. echo on